package cn.com.blueInfo.bpm.common.request;

import cn.com.blueInfo.bpm.common.validation.Create;
import cn.com.blueInfo.bpm.common.validation.Update;
import cn.com.blueInfo.bpm.common.validation.UpdatePartial;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Null;

/**
 * 公共字段接收类
 * @author suxch
 * @since 2025-08-24 01:37:55
 */
@Data
@EqualsAndHashCode(callSuper = true)
public class BaseDTO extends BaseCommonDTO {
    /** ID */
    @NotNull(message = "ID不能为空", groups = {Update.class, UpdatePartial.class})
    @Null(message = "新增ID自动生成", groups = Create.class)
    @Schema(description = "ID")
    private Long id;

}
